<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
    <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
    <c:if test="${requestScope.oP==null }">
    	 <jsp:forward page="LoadServlet" />
    </c:if>
   
<!DOCTYPE html>
<html lang="en">
<script src="js/jquery-3.7.1.js" type="text/javascript"></script>
<style>
	#li_resgin{
		position: relative;
		margin-top:13px;
	}
	#exit{
		float: right;
		color:white;
	}
</style>
<head>
	<meta charset="UTF-8">
	<title>终点小说</title>
</head>
<%
String random=Math.random()+"";
request.setAttribute("random", random);
%>
<link rel="stylesheet" href="css/index.css?v=${random }">
<link rel="stylesheet" href="css/index_gxh.css?v=${random }">
<body>
	<div class="all">
	<section id="popup">欢迎您尊敬的kghkrfj<span></span></section>
		<div class="top-nav" >
			<ul>
				  
				  <li><a href="index.jsp">终点中文网</a></li>
				  <li><a href="#contact"></a></li>
				  <li id="clock_li">
				  	<div id="clock" class="clock"></div>
				  </li>
				  
				  <c:if test="${sessionScope.user==null }">
					  <li id="li_login"><a href="rigister.jsp">注册</a></li>
					  <li id="li_login"><a href="#" >登录</a></li>
				  </c:if>
				    <c:if test="${sessionScope.user!=null }">
				    <li id="exit"> <a href="ExitServlet">退出</a> </li>
					  <li id="li_resgin">欢迎你！${sessionScope.user.userNickName }</li>
					 
				  </c:if>
			</ul>
	    </div>
      
        <div id="myModal" class="modal">
          <h1>登录</h1>
          <div id="consl_xx">
            ✕
          </div>
          <form action="#" method="get">
            <label for="username">用户uid或手机号:</label><br>
            <input type="text" id="userId" name="userId"><br>
            <label for="userPass">密码:</label><br>
            <input type="password" id="userPass" name="userPass"><br><br>
            <input type="button" value="登录" id="login_button">
            <p class="login_p_text"></p>
          </form>
        
      </div>
	    <div class="logo_select_shopcar" style="height:160px">
	    	<div id="div_logo_all">
	    		<div id="div_logo">
	           <div id="logo"><img alt="logo" src="images/logo.png" style="width:300px;height:120px;"></div>
	           <div id="logo_text">六组旗下网页</div>
          </div>
	    	</div>
	    	<div id="search_se">
	    		<div id="search">
	    			<div class="search-container">
					  <form action="MessageServlet" method="get">
					    <input type="text" placeholder="输入您想找的书名或作者" name="mytext" required id="search_input">
					    <button type="submit">搜索</button>
					  </form>
					</div>
	    		</div>
	    	</div>
	    	<div id="myshopcar_div">
           <div id="shoppingcar">
              <a href="UserCenterServlet" >我的书架</a>
           </div>
            
        </div>
	    </div>
      <div class="main_nav"><!-- 导航nav-->
        <ul>
          <li class="groupzp"><a>作品分类</a></li>
          <li><a href="selectBookByTypeServlet?typeName=历史">历史</a></li>
          <li><a href="selectBookByTypeServlet?typeName=现实">现实</a></li>
          <li><a href="selectBookByTypeServlet?typeName=科幻">科幻</a></li>
          <li><a href="selectBookByTypeServlet?typeName=游戏">游戏</a></li>
          <li><a href="selectBookByTypeServlet?typeName=玄幻">玄幻</a></li>
          <li><a href="selectBookByTypeServlet?typeName=体育">体育</a></li>
          <li id="apper"><a href="selectBookByTypeServlet?typeName=武侠">武侠</a></li>
          <li><a href="selectBookByTypeServlet?typeName=历史">页游</a></li>
        </ul>
      </div>
      <!-- 第二部分 -->
      <div id="one_festival_wrap">
        <div id="one_group_left"><!--左导航-->
          <dl id="one_group_left_dl">
    
         <c:set var="num_z" scope="page" value="1"/>
          <c:forEach var ="item" items="${requestScope.typeList }">
          	<c:if test="${num_z %2==1}">
          	
          		 <dd class="one_group_left_dl_left">
		              <a href="selectBookByTypeServlet?typeName=${item }" title="${item }" >
		                <cite> 
		                <span ><i>${item }</i><b></b></span>
		                </cite>
		              </a>
              </dd>
          	</c:if>
          		<c:if test="${num_z %2==0}">
          		 <dd class="one_group_left_dl_right">
	              <a href="selectBookByTypeServlet?typeName=${item }" title="${item }" >
	                <cite> 
	                <span ><i>${item }</i><b></b></span>
	                </cite>
	              </a>
	              </dd>
          		</c:if>
          		<c:set var="num_z" scope="page" value="${num_z+1 }"/>
          </c:forEach>
           
          </dl>
    
        </div>
    
    
        <div id="middle_c_nav"><!--中导航-->
        <!--轮播图-->
          <div class="one_slider">
          <c:forEach items="${lbList }" var ="novel" varStatus="num">
          <c:if test="${num.index==0 }">
          		<a href="ShuServlet?novelId=${novel.novelId }" class="active"><img class="active" src="image/${novel.novelImgURL }"></a>
          </c:if>
             <c:if test="${num.index!=0 }">
          		<a href="ShuServlet?novelId=${novel.novelId }"><img src="image/${novel.novelImgURL }"></a>
          </c:if>
           
            </c:forEach>
          </div>
          <div class="one_slider_nav" id="one_thumb">
	          <c:forEach items="${lbList }" var ="novel" varStatus="num">
	            <div><a href="ShuServlet?novelId=${novel.novelId }" class="lbf-button" data-eid="${num.index }">${novel.novelName } </a></div>
	            
            </c:forEach>
            </div>
            
         </div>
       
        <div id="one_group_right"><!--右导航-->
            <div id="one_slider_right_top"><!--右上导航-->
                <h3><a href="#">题材获奖名单</a></h3>
                <div id="one_notice_list">
                  <ul>
                    <c:set var="num_z" scope="page" value="1"/>
          <c:forEach var ="item" items="${requestScope.typeList }">
          		  <li class="one_list_li">
                      <a href="#"> 
                        <i>「</i>
                        <span>资讯</span>
                        <i>」</i>
                        <span>第${num_z }届现实题材征文${item }</span>
                      </a>
                    </li>
     
          		<c:set var="num_z" scope="page" value="${num_z+1 }"/>
          </c:forEach>
                   
                  </ul>
                  <div id="one_lunbo_text">
                      <div>✉</div>
                      <span>
                        <a href="#">100w</a>
                        <a href="#">天机尾巴支持</a>
                        <a href="#">综合洗涤</a>
                      </span>
          
                  </div>
                </div>
            </div>
            <div id="one_slider_right_buttom"><!--右下导航-->
                <a href="#"><img src="images/fa44d7ba7d84c6afe5ebf873108bb3a1.jpg"></a>
            </div>
        </div>
      </div>

    
      <!-- 郭的页面 -->
      <div id="twodiv1">
        <div id="twodiv2" class="twodiv2_one">
            <h3 class="twoh31">本周强推<a href="twomorebook"><span class="twomore">更多</span></a></h3>
          <div>
          <ul id="twoul1">
            <c:forEach var ="item" items="${requestScope.type_novelName_List[0] }" varStatus="status">
            	 <li>
	              <span class="twoli">
	                <a href="selectBookByTypeServlet?typeName=${item } ">[${item }*</a>
	                 <a href="selectBookByTypeServlet?typeName=${type_novelName_List.get(4)[status.index] } ">${type_novelName_List.get(4)[status.index] }]</a>
	                <a href="ShuServlet?novelId=${requestScope.type_novelName_List.get(3)[status.index] }">${requestScope.type_novelName_List.get(1)[status.index]}</a> 
	              </span>
	            </li>
            </c:forEach>
            <li>
              <span class="twoli">
                <a href="">[页游]</a>
                <a href="">爽玩经典传奇</a>
              </span>
            </li>
          </ul>
          </div>
        </div>
        <div id="twodiv4">
          <div id="twodiv9">
            <h3 class="twoh32">编辑推荐</h3>
            <div id="twodiv5">
              <a href="ShuServlet?novelId=${ttNovelListone[0].novelId }"><img class="active" src="image/${ttNovelListone[0].novelImgURL }" alt=""></a>
            
            </div>
            <div id="twodiv6">
              <div id="twodiv7">
                <h3 class="twoh33">${ttNovelListone[0].novelName }</h3>
                <p>${ttNovelListone[0].novelIntroduction }</p>
                <div id="twodiv8"><a id="twoa1" href="ShuServlet?novelId=${ttNovelListone[0].novelId }">书籍详情</a></div>
              </div>
            </div>
          </div>
          <div id="two_jshao">
            <ul id="twoul2"> 
              <li id="twoli1">
                <h3><a id="twoa4" href="ShuServlet?novelId=${requestScope.novelHitsList[0].novelId}">${requestScope.novelHitsList[0].novelName}</a></h3>
                <em class="twototal">
                  <cite>${requestScope.novelHitsList[0].hits}</cite>
                  <i>人浏览过</i>
                </em>
                <p id="twop1">${requestScope.novelHitsList[0].novelIntroduction}</p>
              </li>  
              <li id="twoli2">
                <h3><a id="twoa4" href="ShuServlet?novelId=${requestScope.novelHitsList[1].novelId}">${requestScope.novelHitsList[1].novelName}</a></h3>
                <em class="twototal">
                  <cite>${requestScope.novelHitsList[1].hits}</cite>
                  <i>人浏览过</i>
                </em>
                <p id="twop2">${requestScope.novelHitsList[1].novelIntroduction}</p>
              </li>  
              <li id="twoli3">
                <h3><a id="twoa4" href="ShuServlet?novelId=${requestScope.novelHitsList[2].novelId}">${requestScope.novelHitsList[2].novelName}</a></h3>
                <em class="twototal">
                  <cite>${requestScope.novelHitsList[2].hits}</cite>
                  <i>人浏览过</i>
                </em>
                <p id="twop3">${requestScope.novelHitsList[2].novelIntroduction}</p>
              </li> 
              </ul>
          </div>
          <div id="two_jshao">
            <ul id="twoul2"> 
              <li id="twoli1">
                <h3><a id="twoa4" href="ShuServlet?novelId=${requestScope.novelHitsList[3].novelId}">${requestScope.novelHitsList[3].novelName}</a></h3>
                <em class="twototal">
                  <cite>${requestScope.novelHitsList[3].hits}</cite>
                  <i>人浏览过</i>
                </em>
                <p id="twop1">${requestScope.novelHitsList[3].novelIntroduction}</p>
              </li>  
              <li id="twoli2">
                <h3><a id="twoa4" href="ShuServlet?novelId=${requestScope.novelHitsList[4].novelId}">${requestScope.novelHitsList[4].novelName}</a></h3>
                <em class="twototal">
                  <cite>${requestScope.novelHitsList[4].hits}</cite>
                  <i>人浏览过</i>
                </em>
                <p id="twop2">${requestScope.novelHitsList[4].novelIntroduction}</p>
              </li>  
              <li id="twoli3">
                <h3><a id="twoa4" href="ShuServlet?novelId=${requestScope.novelHitsList[5].novelId}">${requestScope.novelHitsList[5].novelName}</a></h3>
                <em class="twototal">
                  <cite>${requestScope.novelHitsList[5].hits}</cite>
                  <i>人浏览过</i>
                </em>
                <p id="twop3">${requestScope.novelHitsList[5].novelIntroduction}</p>
              </li> 
              </ul>
          </div>
        </div>
        <div id="twodiv2" class="twodiv2_two">
            <h3 class="twoh31">本周强推2<a href="twomorebook"><span class="twomore">更多</span></a></h3>
          <div>
          <ul id="twoul1">
           <c:forEach var ="item" items="${requestScope.type_novelName_List1[0] }" varStatus="status">
            	 <li>
	              <span class="twoli">
	                <a href="selectBookByTypeServlet?typeName=${item } ">[${item }*</a>
	                <a href="selectBookByTypeServlet?typeName=${type_novelName_List1.get(4)[status.index] } ">${type_novelName_List1.get(4)[status.index] }]</a>
	                <a href="ShuServlet?novelId=${requestScope.type_novelName_List1.get(3)[status.index] }">${requestScope.type_novelName_List1.get(1)[status.index]}</a> 
	              </span>
	            </li>
            </c:forEach>
            <li>
              <span class="twoli">
                <a href="#">[页游]</a>
                <a href="#">爽玩经典传奇</a>
              </span>
            </li>
          </ul>
          </div>
        </div>
      </div>
      <!--坤的页面-->
      <link rel="stylesheet" href="css/numero3.css?v=${random }">
      <div class="rank-wrap box-center " >
        <div id="numero3">
          <div id="rank-list-row" class="rank-list-row cf mb20">
            <!-- 第一个 -->
            <div class="rank-list" data-l2="1">
              <h3 class="wrap-title lang">
                <a href="#" >天榜<i>·</i>新作</a>
                <a class="more" href="#"  
                  >更多<em class="iconfont">></em>
                </a>
              </h3>
              <div class="book-list">
                <ul>
                   <c:forEach var ="item" items="${requestScope.novelVipList}" varStatus="status">
                  		<c:if test="${status.index==0 }">
		                  		<li class="unfold" >
		                    <div class="book-wrap cf">
		                      <div class="book-info fl">
		                        <h3>NO.1</h3>
		                        <h2>
		                          <a href="ShuServlet?novelId=${item.novelId }" 
		                            >${item.novelName }</a>
		                        </h2>
		                        <p class="digital"><em>${item.hits }</em>阅读</p>
		                        <p class="author">
		                          <a class="type" href="selectBookByTypeServlet?typeName=${item.novelTypeName }" >${item.novelTypeName }</a><i>·</i>
		                         <a class="type" href="selectBookByTypeServlet?typeName=${item.novelTypeName2 }" >${item.novelTypeName2 }</a><i>·</i>
		                          <a  class="writer" href="WriterServlet?writerId=${item.writerId }" ">${item.writerName }</a>
		                        </p>
		                      </div>
		                      <div class="book-cover">
		                        <a class="link" href="ShuServlet?novelId=${item.novelId } " 
		                          ><img src="image/${item.novelImgURL }"
		                            alt="${item.novelName }" /> </a><span></span>
		                      </div>
		                    </div>
		                  </li>
                  		</c:if>
                  		<c:if test="${status.index!=0 }">
	                  		<li data-rid="${status.index+1 }">
			                    <div class="num-box"><span class="num${status.index+1 }">${status.index+1 }</span></div>
			                    <div class="name-box">
			                      <a class="name" href="ShuServlet?novelId=${item.novelId }" target="_blank" 
			                        >${item.novelName}</a><i class="total">${item.hits }</i>
			                    </div>
		                   </li>
                  		</c:if>
                  </c:forEach>
                </ul>
              </div>
            </div>
            <!-- 第二个 -->
            <div class="rank-list sort-list" data-l2="2">
              <h3 class="wrap-title lang">
                <a href="#" target="_blank">畅销榜</a>
                <a class="more" href="#"  rel="nofollow"
                  target="_blank">更多<em class="iconfont"> -</em></a>
              </h3>
              <div class="book-list">
                <ul>
                 <c:forEach var ="item" items="${requestScope.novelVipList2}" varStatus="status">
                 		<c:if test="${status.index==0 }">
                 			<li class="unfold" data-rid="1">
			                    <div class="book-wrap cf">
			                      <div class="book-info fl">
			                        <h3>NO.1</h3>
			                        <h2>
			                          <a href="ShuServlet?novelId=${item.novelId }" target="_blank" 
			                            >${item.novelName }</a>
			                        </h2>
			                        <p class="digital f16">销量冠军</p>
			                        <p class="author">
			                        <a class="type" href="selectBookByTypeServlet?typeName=${item.novelTypeName2 }" >${item.novelTypeName2 }</a><i>·</i>
			                          <a class="type" href="selectBookByTypeServlet?typeName=${item.novelTypeName }" ">${item.novelTypeName }</a><i>·</i><a
			                            class="writer" href="WriterServlet?writerId=${item.writerId }" >${item.writerName }</a>
			                        </p>
			                      </div>
			                      <div class="book-cover">
			                        <a class="link" href="ShuServlet?novelId=${item.novelId }"   >
			                        <img src="image/${item.novelImgURL }" alt="${item.novelName }" />
			                        </a><span></span>
			                      </div>
			                    </div>
			                  </li>
                 		</c:if>
                 		<c:if test="${status.index!=0 }">
                 		 <li data-rid="${status.index+1 }">
		                    <div class="num-box"><span class="num${status.index+1 }">${status.index+1 }</span></div>
		                    <div class="name-box">
		                      <a class="name" href="ShuServlet?novelId=${item.novelId }" target="_blank" 
		                       >${item.novelName}</a>
		                      <span class="iconfont">-</span>
		                    </div>
		                  </li>
		         	</c:if>
                 </c:forEach>
                  
                </ul>
              </div>
            </div>

            <div class="rank-list sort-list" data-l2="3">
              <h3 class="wrap-title lang">
                <a href="#" target="_blank">书友榜</a>
                <a class="more" href="#" rel="nofollow" target="_blank"
                  >更多<em class="iconfont"> </em></a>
              </h3>
              <div class="book-list">
                <ul>
                <c:forEach var ="item" items="${requestScope.novelVipList3}" varStatus="status">
                 		<c:if test="${status.index==0 }">
                 			<li class="unfold" data-rid="1">
			                    <div class="book-wrap cf">
			                      <div class="book-info fl">
			                        <h3>NO.1</h3>
			                        <h2>
			                          <a href="ShuServlet?novelId=${item.novelId }" 
			                            >${item.novelName }</a>
			                        </h2>
			                        <p class="digital f16">销量冠军</p>
			                        <p class="author">
			                         <a class="type" href="selectBookByTypeServlet?typeName=${item.novelTypeName2 }" >${item.novelTypeName2 }</a><i>·</i>
			                          <a class="type" href="selectBookByTypeServlet?typeName=${item.novelTypeName }" target="_blank">${item.novelTypeName }</a><i>·</i><a
			                            class="writer" href="WriterServlet?novelTypeId=${item.writerId }" >${item.writerName }</a>
			                        </p>
			                      </div>
			                      <div class="book-cover">
			                        <a class="link" href="ShuServlet?novelId=${item.novelId }"
			                         ><img src="image/${item.novelImgURL }" alt="${item.novelName }" />
			                        </a><span></span>
			                      </div>
			                    </div>
			                  </li>
                 		</c:if>
                 		<c:if test="${status.index!=0 }">
                 		 <li data-rid="${status.index+1 }">
		                    <div class="num-box"><span class="num${status.index+1 }">${status.index+1 }</span></div>
		                    <div class="name-box">
		                      <a class="name" href="ShuServlet?novelId=${item.novelId }" target="_blank" 
		                       >${item.novelName}</a>
		                      <span class="iconfont">-</span>
		                    </div>
		                  </li>
		                 </c:if>
                 		
                 </c:forEach>
                </ul>
              </div>
            </div>
            <div class="rank-list sort-list" data-l2="4">
              <h3 class="wrap-title lang">
                <a href="#" target="_blank">阅读指数榜</a>
                <a class="more" href="#" target="_blank"
                  >更多<em class="iconfont"> </em></a>
              </h3>
              <div class="book-list">
                <ul>
                 	                <c:forEach var ="item" items="${requestScope.novelVipList4}" varStatus="status">
                 		<c:if test="${status.index==0 }">
                 			<li class="unfold" data-rid="1">
			                    <div class="book-wrap cf">
			                      <div class="book-info fl">
			                        <h3>NO.1</h3>
			                        <h2>
			                          <a href="ShuServlet?novelId=${item.novelId }" target="_blank" 
			                            >${item.novelName }</a>
			                        </h2>
			                        <p class="digital f16">销量冠军</p>
			                        <p class="author">
			                         <a class="type" href="selectBookByTypeServlet?typeName=${item.novelTypeName2 }" >${item.novelTypeName2}</a><i>·</i>
			                          <a class="type" href="selectBookByTypeServlet?typeName=${item.novelTypeName }" target="_blank">${item.novelTypeName }</a><i>·</i><a
			                            class="writer" href="WriterServlet?novelTypeId=${item.writerId }" target="_blank">${item.writerName }</a>
			                        </p>
			                      </div>
			                      <div class="book-cover">
			                        <a class="link" href="ShuServlet?novelId=${item.novelId }" target="_blank"
			                         ><img src="image/${item.novelImgURL }" alt="${item.novelName }" />
			                        </a><span></span>
			                      </div>
			                    </div>
			                  </li>
                 		</c:if>
                 		<c:if test="${status.index!=0 }">
                 		 <li data-rid="${status.index+1 }">
		                    <div class="num-box"><span class="num${status.index+1 }">${status.index+1 }</span></div>
		                    <div class="name-box">
		                      <a class="name" href="ShuServlet?novelId=${item.novelId }" target="_blank" 
		                       >${item.novelName}</a>
		                      <span class="iconfont">-</span>
		                    </div>
		                  </li>
		                  </c:if>
                 </c:forEach>
                </ul>
              </div>
            </div>
            <div class="rank-list sort-list mr0" data-l2="5">
              <h3 class="wrap-title lang">
                <a href="#" target="_blank">签约作者新书榜</a>
                <a class="more" href="#" rel="nofollow"      >更多<em class="iconfont"> </em></a>
              </h3>
              <div class="book-list">
                <ul>
              			                
              		<c:forEach var ="item" items="${requestScope.novelVipList5}" varStatus="status">
                 		<c:if test="${status.index==0 }">
                 			<li class="unfold" data-rid="1">
			                    <div class="book-wrap cf">
			                      <div class="book-info fl">
			                        <h3>NO.1</h3>
			                        <h2>
			                          <a href="ShuServlet?novelId=${item.novelId }" target="_blank" 
			                            >${item.novelName }</a>
			                        </h2>
			                        <p class="digital f16">销量冠军</p>
			                        <p class="author">
			                         <a class="type" href="selectBookByTypeServlet?typeName=${item.novelTypeName2 }" >${item.novelTypeName2 }</a><i>·</i>
			                          <a class="type" href="selectBookByTypeServlet?typeName=${item.novelTypeName }" >${item.novelTypeName }</a><i>·</i><a
			                            class="writer" href="WriterServlet?novelTypeId=${item.writerId }" >${item.writerName }</a>
			                        </p>
			                      </div>
			                      <div class="book-cover">
			                        <a class="link" href="ShuServlet?novelId=${item.novelId }"    ><img src="image/${item.novelImgURL }" alt="${item.novelName }" />
			                        </a><span></span>
			                      </div>
			                    </div>
			                  </li>
                 		</c:if>
                 		<c:if test="${status.index!=0 }">
                 		 <li data-rid="${status.index+1 }">
		                    <div class="num-box"><span class="num${status.index+1 }">${status.index+1 }</span></div>
		                    <div class="name-box">
		                      <a class="name" href="ShuServlet?novelId=${item.novelId }" 
		                       >${item.novelName}</a>
		                      <span class="iconfont">-</span>
		                    </div>
		                  </li>
		                  </c:if>
                 </c:forEach>
                </ul>
              </div>
            </div>
          </div>
          <br>
         
        </div>
      </div>

      <!-- ------------------------宝---------------- -->
      <link rel="stylesheet" href="css/xs.css?v=${random }">
      <div class="new-rec-wrap box-center cf" >
        <div class="left-wrap fl">
          <h3 class="wrap-title lang">新书推荐<span>上周入库n本</span></h3>
          <div class="left-info fl" >
            <div class="slide-box">
              <ul id="left-slide-03" 
                style="display: block; padding: 0px; position: relative;">
                <li class="book1 "  
                  data-width="93px" data-height="100%" 
                  style="position: absolute; left: 18px; top: -13px; width: 83.9931px; height: 111.997px; opacity: 1; z-index: 280; font-size: 16px;">
                  <a href="ShuServlet?novelId=${requestScope.newNovelList[0].novelId }" >
                    <img class="lazy" src="image/${requestScope.newNovelList[0].novelImgURL }" style=""></a></li>
              </ul>
            </div>
            <div class="info-text">
              <dl>
                <dd >
                  <h3><a href="ShuServlet?novelId=${requestScope.newNovelList[0].novelId }"
                     >${requestScope.newNovelList[0].novelName }</a></h3>
                  <p class="author"><a href="WriterServlet?writerId=${newNovelList[0].writerId }" 
                      >${requestScope.newNovelList[0].writerName }</a><em>·</em>日更千字</p>
                  <p class="total"><b>${requestScope.newNovelList[0].hits }</b><span>人在追</span></p>
                  <p class="intro"> ${newNovelList[0].novelIntroduction } </p>
                  <a class="read-btn"  href="ShuServlet?novelId=${requestScope.newNovelList[0].novelId }"    >书籍详情</a>
                </dd>
               
              </dl>
            </div>
          </div>
          <div class="center-book-list fl" >
            <div class="line line1"></div>
            <div class="line line2"></div>
            <ul>
            	<c:forEach var ="item" items="${requestScope.newNovelListMore}" varStatus="status">
            			<li data-rid="${status.index+1 }">
			                <div class="book-img"><a href="ShuServlet?novelId=${item.novelId }" 
			                   ><img class="lazy"
			                      src="image/${item.novelImgURL }"
			                      
			                      alt="${item.novelName }" style=""> </a></div>
			                <div class="book-info">
			                  <h3><a href="ShuServlet?novelId=${item.novelId }" target="_blank"  title="${item.novelName }">${item.novelName }</a></h3>
			                  <p>　${item.novelIntroduction }</p>
			                  <div class="state-box cf"><span>日更${status.index+1 }千+</span><i>${item.novelTypeName }</i><i>${item.novelTypeName2 }</i><a class="author"
			                      href="WriterServlet?writerId=${item.writerId }"  >
			                      <img src="images/user.png">${item.writerName }</a></div>
			                </div>
             		 </li>
            			
            	</c:forEach>
            </ul>
          </div>
        </div>
        <div class="right-wrap fr">
          <div class="rank-list sort-list" >
            <h3 class="wrap-title lang">新人<i>·</i>签约新书榜 <a class="more" href="#"
                 target="_blank">更多<em class="iconfont"></em></a></h3>
            <div class="book-list">
              <ul>
               			  <c:forEach var ="item" items="${requestScope.newNovelListMoreTen}" varStatus="status">
                 		<c:if test="${status.index==0 }">
                 			<li class="unfold" data-rid="1">
			                    <div class="book-wrap cf">
			                      <div class="book-info fl">
			                        <h3>NO.1</h3>
			                        <h2>
			                          <a href="ShuServlet?novelId=${item.novelId }"  
			                            >${item.novelName }</a>
			                        </h2>
			                        <p class="digital f16">销量冠军</p>
			                        <p class="author">
			                        <a class="type" href="selectBookByTypeServlet?typeName=${item.novelTypeName2 }" >${item.novelTypeName2 }</a><i>·</i>
			                          <a class="type" href="selectBookByTypeServlet?typeName=${item.novelTypeName }" >${item.novelTypeName }</a><i>·</i>
			                          <a  class="writer" href="WriterServlet?writerId=${item.writerId }" >${item.writerName }</a>
			                        </p>
			                      </div>
			                      <div class="book-cover">
			                        <a class="link" href="ShuServlet?novelId=${item.novelId }" 
			                         ><img src="image/${item.novelImgURL }" alt="${item.novelName }" />
			                        </a><span></span>
			                      </div>
			                    </div>
			                  </li>
                 		</c:if>
                 		<c:if test="${status.index!=0 }">
                 		 <li data-rid="${status.index+1 }">
		                    <div class="num-box"><span class="num${status.index+1 }">${status.index+2 }</span></div>
		                    <div class="name-box">
		                      <a class="name" href="ShuServlet?novelId=${item.novelId }" 
		                       >${item.novelName}</a>
		                      <span class="iconfont">-</span>
		                    </div>
		                  </li>
		                  </c:if>
                 </c:forEach>
                 
              </ul>
            </div>
          </div>
        </div>
      </div>

      <!-- ---------------国--------------- -->
      <link rel="stylesheet" href="css/wanmei.css?v=${random }">
      <div class="finish-book-wrap box-center" >
        <div class="cf" id="numero4">
            <div class="left-wrap fl">
                <h3 class="wrap-title lang">完本精品<span>完本总数n本</span><a class="more" href="#"
                        target="_blank" >更多<em class="iconfont"></em></a></h3>
                <div class="left-info fl" >
                    <div class="slide-box">
                        <ul id="left-slide-02" 
                            style="display: block; padding: 0px; position: relative;">

                            <li class="book2 " 
                                data-width="93px" data-height="100%" data-rid="2"
                                style="position: absolute; left: 18px; top: -13px; width: 83.9931px; height: 111.997px; opacity: 1; z-index: 280; font-size: 16px;">
                                <a href="ShuServlet?novelId=${requestScope.endNovelListone[0].novelId } " 
                                    ><img class="lazy"
                                        src="image/${requestScope.endNovelListone[0].novelImgURL } "
                                       
                                        alt="${requestScope.endNovelListone[0].novelName }" style=""></a></li>
                         
                        </ul>
                    </div>
                    <div class="info-text">
                        <dl>

                            <dd data-rid="2" style="display: block;">
                                <h3><a href="ShuServlet?novelId=${requestScope.endNovelListone[0].novelId }" target="_blank" 
                                       >${requestScope.endNovelListone[0].novelName }</a></h3>
                                <p class="author"><span>n万字</span></p>
                                <p class="total"><b>${requestScope.endNovelListone[0].hits }</b><span>阅读量</span></p>
                                <p class="intro"> ${requestScope.endNovelListone[0].novelIntroduction }</p><a class="read-btn"
                                    href="ShuServlet?novelId=${requestScope.endNovelListone[0].novelId }" target="_blank"
                                   >书籍详情</a>
                            </dd>
                            
                        </dl>
                    </div>
                </div>
                <div class="center-book-list fl" data-l2="2">
                    <div class="line line1"></div>
                    <div class="line line2"></div>
                    <ul>
                       <c:forEach var ="item" items="${requestScope.endNovelListmore}" varStatus="status">
            			<li data-rid="${status.index+1 }">
			                <div class="book-img"><a href="ShuServlet?novelId=${item.novelId }" 
			                   ><img class="lazy"
			                      src="image/${item.novelImgURL }"
			                      alt="${item.novelName }" style=""> </a></div>
			                <div class="book-info">
			                  <h3><a href="ShuServlet?novelId=${item.novelId }"   title="${item.novelName }">${item.novelName }</a></h3>
			                  <p>　${item.novelIntroduction }</p>
			                  <div class="state-box cf"><span>日更${status.index+1 }千+</span><i>${item.novelTypeName }</i><i>${item.novelTypeName2 }</i><a class="author"
			                      href="WriterServlet?writerId=${item.writerId }"  ><img
			                        src="images/user.png">${item.writerName }</a></div>
			                </div>
             		 </li>
            			
            	</c:forEach>
                    </ul>
                </div>
            </div>
            <div class="right-wrap recent-finish-wrap fr">
                <div class="score-list" data-l2="3">
                    <h3 class="wrap-title lang">完本排行</h3>
                    <div class="book-list">
                        <ul>
                        <c:forEach var ="item" items="${requestScope.endNovelListpp}" varStatus="status">
                        	<c:if test="${status.index==0 }">
                        			<li class="unfold" data-rid="1">
		                                <div class="book-wrap cf">
		                                    <div class="book-info fl">
		                                        <h3>${item.novelTypeName }</h3>
		                                        <h2><a href="ShuServlet?novelId=${item.novelId }" 
		                                                >${item.novelName }</a></h2>
		                                        <p class="score">n万字</p>
		                                        <p class="author"><a class="writer" href="WriterServlet?writerId=${item.writerId }"  >${item.writerName }</a></p>
		                                    </div>
		                                    <div class="book-cover"><a class="link" href="#?novelId=${item.novelId }"  >
		                                    <img   src="image/${item.novelImgURL }" > </a><span></span></div>
		                                </div>
		                            </li>
                        	</c:if>
                        	<c:if test="${status.index!=0 }">
                        	 <li><a class="name" href="ShuServlet?novelId=${item.novelId }" 
                                     title="${item.novelIntroduction }">${item.novelIntroduction }</a><i>${item.hits }点击量</i></li>
                        	
                        	</c:if>
                        </c:forEach>
                           
                        </ul>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <!-- ---------------------最近更新---------恒--------- -->
    <link rel="stylesheet" href="css/zjgx.css?v=${random }">
    <div  class="four-new-god">
      <div class="four-new">
        <div class="four-new-book-top">
          <div class="four-new-book-top1">
            <h3>最近更新</h3>
          </div>
          <div class="four-new-book-top2">
            <p class="four-quanBu">全部<a href="">&nbsp;|&nbsp;更多></a></p>
            
          </div>
        </div>
        <div class="four-new-book">
         <c:forEach var ="item" items="${requestScope.novelN}" varStatus="status">
         		 <div class="four-new-book${status.index+1 }">
		            <div class="four-new-book${status.index+1 }-img">
		              <a href="ShuServlet?novelId=${item.novelId }"><img src="image/${item.novelImgURL }" alt=""></a>
		            </div>
		            <div class="four-new-book${status.index+1 }-nie">
		              <ul>
		                <li><a href="ShuServlet?novelId=${item.novelId }"><h3>${item.novelName }</h3></a></li>
		                <li style="color:red"><h5>日更千字</h5></li>
		                <li><a href="WriterServlet?writerId=${item.writerId }" class="four-zuozhe"><h5>${item.writerName }</h5></a></li>
		              </ul>
		            </div>
		          </div>
         </c:forEach>
          
          
        </div>
        <div class="four-table">
          <table>
           		<c:forEach var ="item" items="${requestScope.noveChapter}" varStatus="status">
           				<tr>
			              <td class="four-new-book-type"><a href="selectBookByTypeServlet?typeName=${item.novelTypeName }">${item.novelTypeName }</a></td>
			              <td class="four-new-book-name"><a href="ShuServlet?novelId=${item.novelId}">${item.novelName }</a></td>
			              <td class="four-new-book-zhangJie"><a href="MessageServlet2?chapterId=${item.chapterId }&novelId=${item.novelId}">${item.chapterName }</a></td>
			              <td class="four-new-book-zuoZhe"><a href="WriterServlet?writerId=${item.writerId }">${item.writerName }</a></td>
			              <td class="four-new-book-time">${item.updateTime }</td>
			           </tr>
           		</c:forEach>
          </table>
        </div>
      </div>
      
    </div>
    <!-- -----------------------------footer--------------- -->
    <link rel="stylesheet" href="css/indexFooter.css?v=${random }">
   
    <div class="footer">
      <h1>终点小说网</h1>
      <span>你不知道的这里都有</span>
    </div>
  </div>
</body>
 <link rel="stylesheet" href="css/end.css?v=${random }">
<script>
    
function updateClock() {
  var now = new Date();
  var weekdays = ['星期天', '星期一', '星期二', '星期三', '星期四', '星期五', '星期六'];
  var day = weekdays[now.getDay()];
  var time = now.toLocaleTimeString('en-US', { hour12: false });
  var date = now.toDateString();
  document.getElementById('clock').innerHTML = time + '<br>' + date + '<br>' + day;
}
updateClock();
setInterval(updateClock, 1000);


//轮播图one
var images = document.querySelectorAll('.one_slider a');
  let currentIndex = 0;
  
  function changeImage(direction) {
    
    images[currentIndex].classList.remove('active');
    currentIndex = (currentIndex + direction + images.length) % images.length;
    //images[currentIndex].classList.parentNode.style.zIndex = 99;
    images[currentIndex].classList.add('active');
    $(".lbf-button").each(function(index,item){
        
        var hrefValue = $(item).attr('data-eid');
        // console.log(hrefValue); // 输出href的值
        $(item).parent().css("background-color",'black');
        
        if(hrefValue==currentIndex){
          // console.log($(item).parent());
          $(item).parent().css("background-color",'rgb(237,66,89)');
        }
   });
  }
  

  setInterval(function() {
    changeImage(1); // Change to next image
  }, 3000);
  $(".lbf-button").each(function(index,item){
        
        var hrefValue = $(item).attr('data-eid');
        console.log(hrefValue); // 输出href的值
  });
  //郭的页面
  window.onload = function() {
	  var currentIndex = 0;
	  var images = document.querySelectorAll('#twodiv5 img');
	  var imageCount = images.length;
	 
	  setInterval(function() {
	    images[currentIndex].classList.remove('active');
	    currentIndex = (currentIndex + 1) % imageCount;
	    images[currentIndex].classList.add('active');
	  }, 3000); // 轮播时间间隔
	};

  //加载更多事件
  function more_load(){
      var valn=$("#load-more").eq(0).text();
      console.log(valn);
      if(valn=="展示更多"){
        $("#numero3").find("li").each(function(index,item){
           var c=$(item).attr("data-rid");
           if(c>10){
            $(item).css("display","block");
            
           }
           $(".rank-wrap").css("height","700");
      });
      $("#load-more").eq(0).text("隐藏更多");
      }else if(valn=="隐藏更多"){
        console.log($("#rank-list-row").find("li"));

        $("#rank-list-row").find("li").each(function(index,item){
           var c=$(item).attr("data-rid");
           if(c>10){
            $(item).css("display","none");
           }
           $(".rank-wrap").css("height","600");
      });
      $("#load-more").eq(0).text("展示更多");
      }
      
  }
  //给li_login 下面a标签添加点击弹出登录页面事件
$("#li_login a").on("click",function(){
	window.location = 'login.jsp';
	return;
  console.log("登录ing");
  $("#myModal").css("display","block");
});
$("#consl_xx").on("click",function(){
	  $("#myModal").css("display","none");
	});
//登录的ajax
$("#login_button").click(function(){
	
	$.ajax({
		"type":"get",
		"url":"UserLoginServlet",
		"data":{
			"userId": $("#userId").val(),
			"userPass":$("#userPass").val()
			},
		"dateType":"JSON",
		"success":function(userjson){
			console.log(userjson);
			var jsonObj = JSON.parse(userjson);
			//console.log(jsonObj.listUser[0].userId);
			var user=jsonObj.listUser[0];
			if(user==null){
				$(".login_p_text").text("您的账号密码输入错误，请检查").css("color","red");
				return;
			}
			if(user.admin==1){
				window.location.href = 'AdminServlet';
			}else{
				if(user.status==0){
					console.log("您的账号处于异常状态请联系管理员解封");
					$(".login_p_text").text("您的账号处于异常状态请联系管理员解封").css("color","red");
				}else{
					if(user.vip==1){
						console.log("欢迎您vip用户");
						   var popup = document.getElementById('popup');
						    popup.style.display = 'block';
						    popup.style.left = (document.body.offsetWidth / 2) - (popup.offsetWidth / 2) + 'px';
						    popup.style.top = '20px'; // 距离页面顶部20px
						    popup.innerHTML="欢迎您尊贵的&nbsp;"+user.userNickName+"<span  style='color:red;'>&nbsp;&nbsp;VIP</span>";
						    $("#li_resgin ").text(user.userNickName).css("margin-top","13px");
						    $("#li_login") .html("你好！<span  style='color:red;'>VIP</span>").css("margin-top","13px");
						   
						    $("#myModal").css("display","none");
						    setTimeout(function(){
						    	popup.style.display = 'none';
						    }, 2000);
						
					}else{
						console.log("欢迎您普通用户");
						var popup = document.getElementById('popup');
					    popup.style.display = 'block';
					    popup.style.left = (document.body.offsetWidth / 2) - (popup.offsetWidth / 2) + 'px';
					    popup.style.top = '20px'; // 距离页面顶部20px
					    popup.innerHTML="欢迎您"+user.userNickName;
					    popup.innerHTML="欢迎您&nbsp;"+user.userNickName;
					    $("#li_resgin ").text(user.userNickName).css("margin-top","13px");
					    $("#li_login") .html("你好！").css("margin-top","13px");
					   
					    $("#myModal").css("display","none");
					    setTimeout(function(){
					    	popup.style.display = 'none';
					    }, 2000);
					}
				}
			}
		},
		"error":function(){
			console.log("失败");
		}
		
	});
	
});
//ajax获取所有东西


//给one——lunbo添加事件
// function one_lunbp(){
//   //获取长度
//   var c=$("#one_lunbo_text").children("span").innerWidth();
//   console.log(c);
//   $("#one_lunbo_text").children("span").css("margin-left",c+20+"px");

// }
// one_lunbp();
// function one_lunbp_move(){
//   console.log(111);
//   var c=$("#one_lunbo_text").children("span").innerWidth();
//   $("#one_lunbo_text").children("span").css("margin-left",c-10+"px");
// }
// setInterval(one_lunbp_move,100);




//给apper添加鼠标移入事件
// $(document).ready(function(){
//   $('#apper').mouseenter(function(){
//     // 获取上标签位置
//     var c=$("#apper").offset();
//     var height=c.top;
//     var width=c.width;
//     console.log(height,width);
//     var divObj=$('<div id="mydownApp"></div>');
//   });
// });

</script>
</html>